<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ include file="/common/include.jsp"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">

<title>资料列表</title>

</head>
<body>
<div class="main">
<div class="main_title">你当前的位置：资料库-资料库查询</div>
<s:form id="s_doc_form" namespace="/documentation" action="documentation!listZlxxPageView.action">
<s:hidden name="pageSize" id="pageSize"/>
<table  cellpadding="1" cellspacing="1" class="search">
      <tr class="listr2">
        <td align="right" class="listr6">资料类别</td>
        <td align="left" class="listr5"><s:select name="searchzlxx.TZllb.id" list="zllbList" listKey="id" listValue="name" headerKey="" headerValue="请选择" cssClass="searchSelect" /></td>    
        <td align="right" class="listr6">资料信息</td>
        <td align="left" class="listr5"><s:textfield name="searchzlxx.title" cssClass="searchInput" /></td>        
      </tr>
      <tr class="listr2">
        <td align="right">&nbsp;</td>
        <td align="left" class="listr5" colspan="3"><input type="submit" name="Submit" value="查询" class="btn"  onmouseover="this.className='btn_hover'" onmouseout="this.className='btn'" />
          <input type="reset" name="Submit2" value="重置" class="btn"  onmouseover="this.className='btn_hover'" onmouseout="this.className='btn'" /></td>
      </tr>
    </table>
</s:form>
<div class="botton"></div>
<table id="res-table" cellpadding="1" cellspacing="1" class="tablelist" >
  <tr class="toptitle"> 
    <td>资料标题</td>	  
    <td>资料类别</td>	 	
	<td>创建时间</td>
	<td>创建人</td>
	<td>最后更新时间</td>
	<td>更新人</td>
	<td>操作</td>
  </tr>
	<tbody>
	<s:iterator value="page.res" status="status">
	<s:if test="#status.even">
	 <tr class="listr1" onmouseover="this.className='listr3'" onmouseout="this.className='listr1'">
	</s:if>
	<s:else>
	 <tr class="listr2" onmouseover="this.className='listr3'" onmouseout="this.className='listr2'">
	</s:else>
	    <td>&nbsp;<s:property value="title" /></td>
	    <td>&nbsp;<s:property value="zllbname" /></td>		
		<td>&nbsp;
			<s:date format="yyyy-MM-dd HH:mm" name="addDate"/>
		</td>
		<td>&nbsp;
			<s:property value="adderId"/>
		</td>
		<td>&nbsp;
			<s:date format="yyyy-MM-dd HH:mm" name="lastUpdateDate"/>
		</td>
		<td>&nbsp;
			<s:property value="updaterId"/>
		</td>
		<td>&nbsp;
			<s:url id="viewUrl" namespace="/documentation"
				action="documentation!viewonlyZlxx">
				<s:param name="id">
					<s:property value="id" />
				</s:param>
				<s:param name="searchzlxx.TZllb.id">
					<s:property value="searchzlxx.TZllb.id" />
				</s:param>
			</s:url>

			<s:a href='%{viewUrl}'>查看资料</s:a>
		</td>
	</tr>
</s:iterator>
	</tbody>
</table>
<table class="tablelist" >
<s:set  var="totle" scope="request" value="page.count"/>
<s:set  var="pageSize" scope="request" value="pageSize"/>
<%
	Integer count = (Integer) request.getAttribute("totle");
	Integer pageSize = (Integer) request.getAttribute("pageSize");
%>
		
	<tr>
	<td class="listr4" align="left" colspan="7">
		
		<pg:pager url="documentation!listZlxxPageView.action" items='<%=count.intValue()%>'
			maxPageItems='<%=pageSize%>' export="currentPage=pageNumber">
			<pg:param name="zllb.name" />
			<pg:param name="pageSize" />
			<pg:index export="pages">
				<table>
				<tr>
				<td>
					当前<b class="fontred"><%= currentPage%></b>/<%=pages%>页&nbsp;&nbsp;&nbsp;&nbsp;
				</td>
				<td>
				<pg:first>
					<a href="<%=pageUrl%>&pageNo=<%=pageNumber%>">首页</a>
				</pg:first>
				</td>
				<td>	
				<pg:prev>
					<a href="<%=pageUrl%>&pageNo=<%=pageNumber%>">上一页</a>
				</pg:prev>
				</td>
				<td>
				<pg:pages>
					<%
						if (currentPage == pageNumber) {
					%>
					<font color="red"><%=pageNumber%></font>
					<%
						} else {
					%>
					<a href="<%=pageUrl%>&pageNo=<%=pageNumber%>"><%=pageNumber%></a>
					<%
						}
					%>
				</pg:pages>
				</td>
				<td>
				<pg:next>
					<a href="<%=pageUrl%>&pageNo=<%=pageNumber%>">下一页</a>
				</pg:next>
				</td>
				<td>
				<pg:last>
					<a href="<%=pageUrl%>&pageNo=<%=pageNumber%>">末页</a>&nbsp;&nbsp;&nbsp;&nbsp;
				</pg:last>
				</td>
				
				<td>
					&nbsp;
				</td>
				<td style="padding-left: 10px;">
					每页显示的记录数
				</td>
				<td>
					<input type="text" class="PageInput" value="<%=pageSize %>" onchange="Ext.get('pageSize').dom.value=this.value;Ext.get('s_doc_form').dom.submit();"/>
				</td>
				<td>
					条
				</td>
				<td>
					&nbsp;
				</td>
				</tr>
				</table>
			</pg:index>

		</pg:pager>
		</td>
	</tr>
</table>
</div>

</body>
</html>